#include <iostream>
#include <string>
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <pthread.h>
#include <assert.h>
#include <sys/time.h>
#include <signal.h>
using namespace std;


    class SimpleTimer{
    private:
    	double timeuse = 0.0;
        struct timeval start;
        struct timeval end;
    public:
    	SimpleTimer(){
    		gettimeofday( &start, NULL );
    	}
    	~SimpleTimer(){
    		gettimeofday( &end, NULL );
            timeuse = 1000000 * ( end.tv_sec - start.tv_sec ) + end.tv_usec - start.tv_usec;
            timeuse = (double)timeuse / 1000;
    		cout << "run：" << timeuse << "ms" << endl;
    	}
    };